home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / scope / 101-125 / scopedisk122 / extract / extract.doc < prev    next >
Text File  |  1995-03-19  |  8KB  |  175 lines

  1.                          Extract by The Mad Scientist
  2.                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  3.  
  4.    This is the documentation for the latest version of Extract, a program to
  5. help you decode text from encrypted (or non-encrypted) binary files.
  6.  
  7.    Have you ever gotten a program that you can't use because you don't have
  8. the code words that it requires (maybe the dog devoured your docs)? It would
  9. be a great help if you could had the list of words that the program picks
  10. from, at least this would be a starting point to get into the program. Or,
  11. perhaps you like to play adventure games, but need one tiny hint to get in
  12. that final dungeon (or maybe you would like to make a walk-through).
  13.  
  14.    Usually, you can't just type or edit the file that contains this valuable
  15. information, typically it is a binary file. And the file is usually
  16. encrypted, so that even if you do type the file, it is just garbage. Extract
  17. is the answer. It will extract just printable characters from any binary
  18. file, and optionally process them according to a de-cryption script that
  19. you specify (see section on scripts). Any part of the file may be printed,
  20. or the final output file (optional) may be loaded into any text editor.
  21.  
  22. USAGE:     Extract source-file
  23. EXAMPLE:   Extract ram:u3mod2.dat    (u3mod2.dat is a Universe 3 data file)
  24.  
  25.    The entire source file is not loaded into memory at once, only one screen
  26. at a time is kept in memory. This allows you to process a file of any size.
  27.  
  28.  
  29. The Gadgets:
  30. ~~~~~~~~~~~~
  31.    Extract-screen.pic shows which gadget is which.
  32.  
  33.    If you click on a gadget and the screen flashes, it usually means that
  34. the option is not available right now. For example, if you try to clear a
  35. script and none is present, or if you enter illegal input into the input
  36. gadget, the screen will flash. The current screen will usually be
  37. displayed after each gadget selection, to update any changes you have made.
  38.  
  39. EXIT        :   This gadget exits the program.
  40.  
  41. Input Gadget:   This gadget is automatically activated when the program
  42.                 requires input. Enter the desired input, and press
  43.                 return. You will have to backspace any leftover input
  44.                 from the previous use of this gadget.
  45.  
  46. Page Up     :   This reads the next section in the source file, and
  47.                 displays it after it is processed by the script. You cannot
  48.                 page down past the end of the file.
  49.  
  50. Page Down   :   This reads the previous section in the source file, and
  51.                 displays it after it is processed by the script. You
  52.                 page up past the beginning of the file.
  53.  
  54. Continue Up :   This toggle gadget is like the page up gadget, except that
  55.                 it will scroll through the entire file until it is clicked
  56.                 of, or until the end of file is reached.
  57.  
  58. Continue Dn :   This toggle gadget is like the page down gadget, except that
  59.                 it will scroll through the entire file until it is clicked
  60.                 of, or until the start of file is reached.
  61.  
  62. P-Format    :   This is a toggle gadget (click on, click again off) that
  63.                 determines what characters are extracted. When this
  64.                 gadget is selected, all printable characters are shown.
  65.                 If it is not selected, only letters are shown.
  66.  
  67. S-Format    :   This toggle gadget determines whether dots (unselected)
  68.                 or spaces (selected) replace non-extracted characters.
  69.                 This gadget affects the way an entire file is processes, see
  70.                 Write File below.
  71.  
  72. Print Screen:   This gadget will send the contents of the current screen
  73.                 to your printer. The printer must be online.
  74.  
  75. Clear Script:   This gadget will clear any script that is in memory.
  76.  
  77. Byte Count  :   This gadget will count the number of each byte in the
  78.                 current file, and send the output to a file you specify.
  79.                 This gadget activates the text gadget, where you must enter
  80.                 the file name to send the byte count to. The most useful place
  81.                 to send a byte count is to the printer (prt:). A byte count
  82.                 table can be VERY useful in determining de-cryption values
  83.                 to use in a script. Characters are counted AFTER the current
  84.                 script is applied.
  85.  
  86. Write File  :   This gadget will process the current file according to the
  87.                 current script, and save the output in a file. This gadget
  88.                 activates the text gadget, where you must enter the file
  89.                 name to send the output to. If the S-Format gadget is
  90.                 selected, spaces will replace non-printable characters. In
  91.                 This mode, the P-Format gadget has no effect, all printable
  92.                 characters are output, not just letters. If the S-Format
  93.                 gadget is not selected, all characters are output after
  94.                 processing, whether they are printable or not.
  95.  
  96.  
  97. Scripts, Script Gadgets, And Decrypt Gadgets
  98. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  99.  
  100.   Scripts are optional. When a script is present, de-cryption values are
  101. applied in the order that they were put into the script. The order is
  102. important, and the same values in different orders will usually have
  103. drastically different results. Scripts may have up to 254 elements, although
  104. most will need only one or two elements.
  105.  
  106. Load  : This will load a script into memory, and apply it to the current
  107.         screen. You may not load a script if one is already present,
  108.         select the Clear Script gadget first. This gadget uses the input
  109.         gadget, enter the name of the script to load in the input gadget.
  110.  
  111. Save  : This will save the the current script (if there is one). This
  112.         gadget also activates the input gadget.
  113.  
  114. <-    : The small back gadget will delete the last entry in the script.
  115.  
  116. Up/Dn : These gadgets are the same (I was lazy, it was late, and I was
  117.         tired), they will display the entire current script.
  118.  
  119. Decrypt Gadgets
  120. ~~~~~~~~~~~~~~~
  121.  
  122.    These gadgets enter add to the end of the current script. They all use
  123. the input gadget (except the NOT gadget) to enter values. The screen will
  124. flash if your input is un-acceptable. You may use any combination of these,
  125. as each element in the script has it's own value.
  126.  
  127. EOR  :  Bitwise EOR bytes with the EOR value.
  128.         Values are from 0 to 255.
  129.  
  130. NOT  :  This inverts the bits in each byte (bitwise NOT).
  131.  
  132. AND  :  Bitwise AND bytes with the AND value.
  133.         Values are from 0 to 255.
  134.  
  135. OR   :  Bitwise OR with the OR with value.
  136.         Values are from 0 to 255.
  137.  
  138. +    :  ADD value to bytes.
  139.         Values are from 0 to 255.
  140.     If a result exceeds 255, it rolls over, for example 255 + 1 = 0.
  141.  
  142. -    :  SUBTRACT value from bytes.
  143.         Values are from 0 to 255.
  144.         If a result is less than 0 it rolls under, for example 0 - 2 = 254.
  145.  
  146. LS   :  Bit shift left by value.
  147.         Values are from 0 to 7.
  148.  
  149. RS   :  Bit shift right by value.
  150.         Values are from 0 to 7.
  151.  
  152. b%x  :  byte MOD value (math remainder function).
  153.         Values are from 1 to 255.
  154.  
  155. x%b  :  value MOD byte (math remainder function).
  156.         Values are from 0 to 255 (0 is somewhat useless).
  157.         Note that if byte = 0, a division by zero error would
  158.         result. These are trapped, and a 0 returned.
  159.  
  160. De-cryption Hints
  161. ~~~~~~~~~~~~~~~~~
  162.  
  163.    Of course, the hard part is comming up with scripts for encrypted
  164. programs, I can't help you much there, but often you will get a clue by
  165. dis-assembling the program in question, or by running it under a debugger.
  166.  
  167.    A byte count table is very useful in de-crypting files. For example, if
  168. all the bytes are grouped together over a small range, you probably just
  169. have to add or subtract. On the other hand, if they are scattered over
  170. all 256 values (0 to 255), then you probably need a combination of functions,
  171. probably MOD and EOR...  You don't actually need the same method that was
  172. used to en-crypt the file, sometimes other functions will produce the
  173. same results.
  174.  
  175.